package com.freejava.testredis.demo.mapper;

import com.freejava.testredis.demo.pojo.Product;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface ProductMapper {
    @Select("select * from rt_products")
    List<Product> getList();

    @Select("select * from rt_products where id = #{id}")
    Product findById(Long id);
}
